package com.wenhao.newcode.huawei;

import java.util.Comparator;
import java.util.Scanner;
import java.util.SortedSet;
import java.util.TreeSet;

/**
 * @author Wenhao Tong
 * @date 2021/7/15 下午10:08
 */
public class MainHJ3 {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int N = scanner.nextInt();
            SortedSet<Integer> integers = new TreeSet<>(new Comparator<Integer>() {
                @Override
                public int compare(Integer o1, Integer o2) {
                    return o1 - o2;
                }
            });
            for (int i = 0;i < N;i++) {
                integers.add(scanner.nextInt());
            }
            for (Integer i : integers) {
                System.out.println(i);
            }
        }
    }
}
